package errors

import (
	"code.gitea.io/gitea/models/repo"
	"code.gitea.io/gitea/models/user"
	"fmt"
)

type ErrDevcontainerAlreadyCreated struct {
	Actor      *user.User
	Repository *repo.Repository
}

func (err ErrDevcontainerAlreadyCreated) Error() string {
	return fmt.Sprintf("Failed to create DevContainer in repo '%s'(repoId = %d) by user '%s'(userId = %d), since it already exists.",
		err.Repository.Name, err.Repository.ID, err.Actor.Name, err.Actor.ID)
}
